package com.ssy.lingxi.contract.entity;

import javax.persistence.*;
import java.io.Serializable;

/**
 * 合同文本
 * @author 伍将
 * @date 2021/1/25
 * @version 2.0.0
 */
@Entity
@Table(schema = "public", name = "con_contract_text",
        indexes = {@Index(name = "con_contract_text_contract_id_idx", columnList = "contractId")})
public class ContractTextDO implements Serializable {
    private static final long serialVersionUID = -53129119282556626L;

    /**
     * ID
     */
    @Id
    @GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "contract_text_seq")
    @SequenceGenerator(sequenceName = "con_contract_text_seq", name = "contract_text_seq", allocationSize = 1)
    private Long id;

    /**
     * 合同id
     */
    @Column(columnDefinition = "int8")
    private Long contractId;

    /**
     * 合同模板id
     */
    @Column(columnDefinition = "int8")
    private Long templateId;

    /**
     * 是否使用电子合同：CommonBooleanEnum
     */
    @Column(columnDefinition = "int")
    private Integer isUseElectronicContract;

    /**
     * 合同名称
     */
    @Column(columnDefinition = "varchar(100)")
    private String contractName;

    /**
     * 合同地址
     */
    @Column(columnDefinition = "varchar(1000)")
    private String contractUrl;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getContractId() {
        return contractId;
    }

    public void setContractId(Long contractId) {
        this.contractId = contractId;
    }

    public Long getTemplateId() {
        return templateId;
    }

    public void setTemplateId(Long templateId) {
        this.templateId = templateId;
    }

    public Integer getIsUseElectronicContract() {
        return isUseElectronicContract;
    }

    public void setIsUseElectronicContract(Integer isUseElectronicContract) {
        this.isUseElectronicContract = isUseElectronicContract;
    }

    public String getContractName() {
        return contractName;
    }

    public void setContractName(String contractName) {
        this.contractName = contractName;
    }

    public String getContractUrl() {
        return contractUrl;
    }

    public void setContractUrl(String contractUrl) {
        this.contractUrl = contractUrl;
    }
}
